import 'package:flutter_taotaoshipin/generated/json/base/json_convert_content.dart';
import 'package:flutter_taotaoshipin/model/userinfo_bind_phone_entity.dart';

UserinfoBindPhoneEntity $UserinfoBindPhoneEntityFromJson(
    Map<String, dynamic> json) {
  final UserinfoBindPhoneEntity userinfoBindPhoneEntity = UserinfoBindPhoneEntity();
  final int? move = jsonConvert.convert<int>(json['move']);
  if (move != null) {
    userinfoBindPhoneEntity.move = move;
  }
  final bool? state = jsonConvert.convert<bool>(json['state']);
  if (state != null) {
    userinfoBindPhoneEntity.state = state;
  }
  final String? userName = jsonConvert.convert<String>(json['user_name']);
  if (userName != null) {
    userinfoBindPhoneEntity.userName = userName;
  }
  final String? userPwd = jsonConvert.convert<String>(json['user_pwd']);
  if (userPwd != null) {
    userinfoBindPhoneEntity.userPwd = userPwd;
  }
  final String? msg = jsonConvert.convert<String>(json['msg']);
  if (msg != null) {
    userinfoBindPhoneEntity.msg = msg;
  }
  return userinfoBindPhoneEntity;
}

Map<String, dynamic> $UserinfoBindPhoneEntityToJson(
    UserinfoBindPhoneEntity entity) {
  final Map<String, dynamic> data = <String, dynamic>{};
  data['move'] = entity.move;
  data['state'] = entity.state;
  data['user_name'] = entity.userName;
  data['user_pwd'] = entity.userPwd;
  data['msg'] = entity.msg;
  return data;
}

extension UserinfoBindPhoneEntityExtension on UserinfoBindPhoneEntity {
  UserinfoBindPhoneEntity copyWith({
    int? move,
    bool? state,
    String? userName,
    String? userPwd,
    String? msg,
  }) {
    return UserinfoBindPhoneEntity()
      ..move = move ?? this.move
      ..state = state ?? this.state
      ..userName = userName ?? this.userName
      ..userPwd = userPwd ?? this.userPwd
      ..msg = msg ?? this.msg;
  }
}